﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace WFApp
{
    public partial class Loading : Form
    {
        public Loading()
        {
            InitializeComponent();
            Start();
        }

        private void Start() {
            IntPtr handle = this.Handle;
            Task.Run(() => {
                for (int i = 0; i <= 100; i++)
                {
                    this.Invoke(() => {
                        this.progressBar1.Value = i;
                    });
                }
                this.Invoke(() => {
                    this.Dispose();
                });
            });
        }
    }
}
